#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QTreeWidget>
#include <QAction>
#include "database.h"
#include "newitemdialog.h"

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    MainWindow(QWidget *parent = nullptr);
    ~MainWindow();

private slots:
    void onNew();
    void onDeleteItem();
    void onEditItem();

private:
    void setupUI();
    void loadData();

    QTreeWidget *treeWidget;
    Database *database;
};

#endif // MAINWINDOW_H